[MySQL, InnoDb] Rating place
Posted
by Pavel
on Stack Overflow
See other posts from Stack Overflow
or by Pavel
Published on 2010-05-28T14:49:23Z
Indexed on
2010/05/28
14:51 UTC
Read the original article
Hit count: 204
I'm trying to generate rating place table using following receipt
http://stackoverflow.com/questions/1776821/assign-places-in-the-rating-mysql-php
but my database is high loaded.
I tried not to create table, but use MEMORY TABLE and update it using following SQL query
insert into tops (uid) select uid from users order by exp desc;
but got the following MySQL error
Deadlock found when trying to get lock; try restarting transaction
because there are too many queries until SQL select is being executed.
How to solve this problem?
P.S. CREATE TABLE tops as SELECT work almost fine except high server load... up to load average: 50 if tops are non-memory table.
My table users has near 4.5 millions of rows.
Thanks for any advices.
© Stack Overflow or respective owner